package com.yellowpage.ca.dao;

import java.util.List;

import org.hibernate.HibernateException;
import org.hibernate.Session;
import org.springframework.orm.hibernate3.HibernateCallback;

import com.yellowpage.ca.data.Role;
import com.yellowpage.ca.data.User;
import com.yellowpage.ca.data.UserRole;
import com.yellowpage.white.dao.BaseDaoHibernateImpl;

public class UserRoleDaoImpl extends BaseDaoHibernateImpl<UserRole, Long>
		implements
			UserRoleDao {

	public UserRoleDaoImpl() {
		super(UserRole.class);
	}
	
	public List getUserRoleIdByRole(Long roleId){
		String queryString = "select ur.userRoleId from UserRole ur where ur.roleId = "
				+ roleId;
		return getHibernateTemplate().find(queryString);
	}

	
	

}
